from django.urls import path

from . import views


urlpatterns = [
    path("", views.index, name="index"),
    path('menu/', views.menu, name='menu'),
    path('books/', views.book_list, name='book_list'),
    path('books/<int:book_id>/', views.book_detail, name='book_detail'),
    path('books/create/', views.book_create, name='book_create'),
    path('books/<int:book_id>/update/', views.book_update, name='book_update'),
    path('books/<int:book_id>/delete/', views.book_delete, name='book_delete'),
    path('books/search/', views.book_search, name='book_search'),
    path('cart/', views.cart, name='cart'),
    path('checkout/success/', views.checkout_success, name='checkout_success'),
    path('books/<int:book_id>/add_to_cart/', views.add_to_cart, name='add_to_cart'),
    path('cart/remove/<int:book_id>/', views.remove_from_cart, name='remove_from_cart'),
]
